<template>
  <div class="container">
    <div class="container-1200">
      <div class="flexWithJusBetween mg-B20">
        <div class="title">项目详情表</div>
      </div>
      <div>
        <div style="color: red; margin-left: 20px">
          审核状态：{{ projectStatusFormate(projectInfo.status) }}
        </div>
        <div style="color: red; margin-left: 20px" v-if="projectInfo.memo">
          驳回说明：{{ projectInfo.memo }}
        </div>
      </div>
      <el-row class="rowBorder rowTopBorder" >
          <el-col :span="12" class="col-flex request bg-ccc colLeftBorder">项目名称</el-col>
          <!-- <el-col :span="4" class="col-flex request bg-ccc colLeftBorder">项目类别</el-col> -->
          <el-col :span="6" class="col-flex request bg-ccc colLeftBorder">企业名称</el-col>
          <el-col :span="6" class="col-flex request bg-ccc colLeftBorder">启动时间</el-col>
          <!-- <el-col :span="6" class="col-flex colLeftBorder bg-ccc">三年计划:投资、预计收益、创就业岗位数</el-col> -->
        </el-row>
        <el-row class="rowBorder" >
          <el-col :span="12" class="col-flex colLeftBorder">
            <div class="colCell minH50 flexWithJusCenter" >
            {{ projectInfo.projectName}}
            </div>
            </el-col>
          <!-- <el-col :span="4" class="col-flex colLeftBorder">
            <div class="colCell minH50 flexWithJusCenter" >
            {{ projectCategoryFormate(projectInfo.projectCategoryId) }}
            </div>
            </el-col> -->
            <el-col :span="6" class="col-flex colLeftBorder">
            <div class="colCell minH50 flexWithJusCenter" >
            {{ projectInfo.compnayName }}
            </div>
            </el-col>
          <el-col :span="6" class="col-flex colLeftBorder">
            <div class="colCell minH50 flexWithJusCenter" >
            {{ dateFormatter(projectInfo.startDate) }}
            </div>
            </el-col>
          <!-- <el-col :span="6" class="col-flex colLeftBorder"> 
            <div class="colCell minH50 flexWithJusCenter" >
            {{ projectInfo.syjh }}
            </div>
            </el-col> -->
        </el-row>
          <el-row class="rowBorder bg-ccc">
          <el-col :span="4" class="col-flex request  colLeftBorder">建设内容</el-col>
            <el-col :span="20" class="col-flex colLeftBorder bg-fff">
            <div class="colCell" >
              {{ projectInfo.jsnr }} 
            </div>
            </el-col>
          </el-row>
          <el-row class="rowBorder bg-ccc">
          <el-col :span="4" class="col-flex request  colLeftBorder">建设目标</el-col>
            <el-col :span="20" class="col-flex colLeftBorder bg-fff">
            <div class="colCell" >
              {{ projectInfo.jsmb }} 
            </div>
            </el-col>
          </el-row>
          <el-row class="rowBorder bg-ccc">
          <el-col :span="4" class="col-flex request  colLeftBorder">项目概述</el-col>
            <el-col :span="20" class="col-flex colLeftBorder bg-fff">
            <div class="colCell" >
              {{ projectInfo.xmgs }} 
            </div>
            </el-col>
          </el-row>
          <el-row class="rowBorder bg-ccc">
          <el-col :span="4" class="col-flex colLeftBorder">商业计划书</el-col>
            <el-col :span="20" class="col-flex colLeftBorder bg-fff">
            <div class="colCell" >
              <el-link :href="projectInfo.meta" target="_blank" type="primary" class="link">商业计划书</el-link> 
            </div>
            </el-col>
          </el-row>

      <!-- <el-row class="rowBorder">
        <el-col :span="24" class="col-flex">企业基本情况（一）</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 request bg-ccc"
          >企业名称</el-col
        >
        <el-col :span="12" class="col-flex leftAlign-pd30 colLeftBorder">{{
          projectInfo.compnayName
        }}</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业负责人</el-col
        >
        <el-col :span="12" class="col-flex leftAlign-pd30 colLeftBorder">{{
          projectInfo.linkman
        }}</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业负责人联系人电话</el-col
        >
        <el-col :span="12" class="col-flex leftAlign-pd30 colLeftBorder">{{
          projectInfo.phone
        }}</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业等级注册类型</el-col
        >
        <el-col :span="12" class="col-flex leftAlign-pd30 colLeftBorder">{{
          registrationFormate(projectInfo.registration)
        }}</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >行业类型</el-col
        >
        <el-col :span="12" class="col-flex leftAlign-pd30 colLeftBorder">{{
          industryFormate(projectInfo.industry)
        }}</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业纳税人类型</el-col
        >
        <el-col :span="12" class="col-flex leftAlign-pd30 colLeftBorder">{{
          taxTypeFormate(projectInfo.taxType)
        }}</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 request bg-ccc"
          >是否高新科技企业</el-col
        >
        <el-col :span="12" class="col-flex leftAlign-pd30 colLeftBorder">{{
          projectInfo.isHighSalary == true ? "是" : "不是"
        }}</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 request bg-ccc"
          >是否科技型中小企业</el-col
        >
        <el-col :span="12" class="col-flex leftAlign-pd30 colLeftBorder">{{
          projectInfo.isKjxzxqy == true ? "是" : "不是"
        }}</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 request bg-ccc"
          >是否有IPO、新三板、并购退出</el-col
        >
        <el-col :span="12" class="col-flex leftAlign-pd30 colLeftBorder">{{
          projectInfo.isIpo == true ? "是" : "不是"
        }}</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 request bg-ccc"
          >融资轮次（种子、天使、A、B、C）</el-col
        >
        <el-col :span="12" class="col-flex leftAlign-pd30 colLeftBorder">{{
          lzjdFormate(projectInfo.lzjd)
        }}</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 request bg-ccc"
          >企业资产估值</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">万元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.zcgz }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc">指标</el-col>
        <el-col :span="4" class="col-flex colLeftBorder">计量单位</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          数量</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="24" class="col-flex">一、企业基本情况</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >获得天使或风险投资额</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.lzjr }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业成立时注册资本</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.zczb }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="24" class="col-flex">二、企业经济情况</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业2020至今的投资额</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.bytz }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业上年总收入</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.sbysl }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >当年获得政府资金</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.dyzfzj }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业净利润</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.qyjll }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业出口总额</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.qyzck }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业研究与试验发展（R&D）经费支出</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.rdjfzc }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业实际上缴税费</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.qysjsjsf }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="24" class="col-flex">三、企业从业人员情况</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >企业从业人员</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">人</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.employeeNum }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd40 bg-ccc"
          >其中：博士</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">人</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.bsyg }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc">硕士</el-col>
        <el-col :span="4" class="col-flex colLeftBorder">人</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.ssyg }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc">本科</el-col>
        <el-col :span="4" class="col-flex colLeftBorder">人</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.bkyg }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc">大专</el-col>
        <el-col :span="4" class="col-flex colLeftBorder">人</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.dzyg }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >留学人员</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">人</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.lxry }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >千人计划人数</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">人</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.zrjlrs }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >百人计划人数</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">人</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.sbrcrs }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >吸纳应届大学毕业生</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">人</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.yjbys }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="24" class="col-flex">四、企业知识产权情况</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >当年知识产权申请数</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">件</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.zscqsq }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >当年只是产权授权数</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">件</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.zscqsqs }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd40 bg-ccc"
          >其中：发明专利</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">件</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.zscqfmzl }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >拥有有效知识产权数</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">件</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.yyzscqs }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd40 bg-ccc"
          >其中：发明专利</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">件</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.yxzscqs }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >软件著作权</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">件</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.rjzzq }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >植物新品种</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.zwxpz }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >集成电路布图</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.jcdlbt }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >PCT专利</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.pct }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >购买国外专利</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">件</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.gmgwzl }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >技术合同交易数量</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">项</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.jshtjys }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >技术合同交易额</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.jshtjyr }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >当年承担国家级科技计划项目数</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">项</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.gjkjxms }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >当年获得市级以上奖励</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">项</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.cjysjl }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="24" class="col-flex">五、产学研合作情况</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >产学研合作项目数</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.cxyhzxm }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >产学研合作项目总金额</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">千元</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.cxyhzjr }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="24" class="col-flex">六、双创载体建设情况</el-col>
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd30 bg-ccc"
          >建设双创载体的数量</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.jssczts }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd40 bg-ccc"
          >其中：孵化器</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.fhq }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >众创空间</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.zckj }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >台青创基地</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.dqjd }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >技术创新中心</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.jscxzx }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >工程研究中心</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.gcyjzx }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >产业创新中心</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.cycxzx }}</el-col
        >
      </el-row>
      <el-row class="rowBorder">
        <el-col :span="12" class="col-flex leftAlign-pd80 bg-ccc"
          >新兴研发机构</el-col
        >
        <el-col :span="4" class="col-flex colLeftBorder">个</el-col>
        <el-col :span="8" class="col-flex leftAlign-pd30 colLeftBorder">
          {{ projectInfo.xxyfjg }}</el-col
        >
      </el-row> -->
      <!-- <el-row class="rowBorder">
        <el-col :span="4" class="col-flex">项目状态</el-col>
        <el-col :span="8" class="col-flex colLeftBorder colRightBorder">{{
          projectStatusFormate(projectInfo.status)
        }}</el-col>
        <el-col :span="4" class="col-flex">驳回说明</el-col>
        <el-col :span="8" class="col-flex colLeftBorder">{{
          projectInfo.memo
        }}</el-col>
      </el-row> -->
      <!-- </div> -->
    </div>
  </div>
</template>

<script>
import ExportList2Excel from "@/components/ExportList2Excel";
import LangSelect from "@/components/LangSelect";
import { validUsername } from "@/utils/validate";
import utils from "@/utils/utils.js";
import { list as dictList } from "@/api/dict";
import { find as projectFind } from "@/api/project";

export default {
  components: { ExportList2Excel },
  name: "projectView",
  data() {
    const validatePassword = (rule, value, callback) => {
      if (value.length < 6) {
        callback(new Error("密码不能少于6位"));
      } else {
        callback();
      }
    };
    return {
      projectId: "",
      projectInfo: {},

      projectStatusDict: [],
      industryDict: [],
      industryDictPromise: "",
      projectCategoryDict: [],
      projectCategoryDictPromise: "",

      //获取字典的promise
      taxTypeDictPromise: "",
      registrationDictPromise: "",
      lzjdDictPromise: "",
      projectStatusPromise: "",

      scroll: "",
    };
  },
  watch: {
    $route: {
      handler: function (route) {},
      immediate: true,
    },
  },

  activated() {
    console.log("activated执行缓存了--", this.$store.getters.closeAliveName );
    if (this.$store.getters.closeAliveName == "projectView") {
      console.log("activated执行了更新了--", this.$store.getters);
      this.projectId = this.$route.query.projectId;
      this.getProjectInfo(this.projectId);
      this.scroll = 0;
      this.$store.dispatch("user/cleanCloseAliveName");
    } else {
      if (this.scroll > 0) {
        window.scrollTo(0, this.scroll);
        this.scroll = 0;
      }
    }
    window.addEventListener("scroll", this.handleScroll);
  },

  deactivated() {
    window.removeEventListener("scroll", this.handleScroll);
  },

  created() {
    console.log("created执行了--");
    this.taxTypeDictPromise = utils.getDictList("tax_type", (res) => {
      this.taxTypeDict = res.data;
    });
    this.registrationDictPromise = utils.getDictList("registration", (res) => {
      this.registrationDict = res.data;
    });
    this.lzjdDictPromise = utils.getDictList("lzjd", (res) => {
      this.lzjdDict = res.data;
    });
    this.projectStatusPromise = utils.getDictList("project_status", (res) => {
      this.projectStatusDict = res.data;
    });
    this.industryDictPromise = utils.getDictList("industry", (res) => {
      this.industryDict = res.data;
    });
    this.projectCategoryDictPromise = utils.getDictList(
      "projectCategory",
      (res) => {
        this.projectCategoryDict = res.data;
      }
    );
  },

  mounted() {
    window.addEventListener("scroll", this.handleScroll);
    Promise.all([
      this.taxTypeDictPromise,
      this.registrationDictPromise,
      this.lzjdDictPromise,
      this.projectStatusPromise,
      this.industryDictPromise,
      this.projectCategoryDictPromise,
    ]).then((res) => {
      console.log("res--", res);
      if (this.$route.query) {
        this.projectId = this.$route.query.projectId;
        this.getProjectInfo(this.projectId);
      }
    });
  },

  destroyed() {},

  methods: {
    //监听滚动条
    handleScroll() {
      let scrollTop = document.documentElement.scrollTop;
      this.scroll = scrollTop;
      console.log("scrollTop--", document.documentElement.scrollTop);
    },

    //获取项目信息
    getProjectInfo(projectId) {
      projectFind(projectId)
        .then((res) => {
          console.log("projectFind成功获取数据--", res);
          if (res.type == "success") {
            this.projectInfo = res.data.project;
          }
        })
        .catch((err) => {
          this.$message.error(err.msg);
        });
    },

    //字典信息获取
    getDictList(type, callback, errCallback) {
      let params = new URLSearchParams();
      params.append("dictType", type);
      return dictList(params)
        .then((res) => {
          console.log(type + "字典--", res);
          if (res.type == "success") {
            if (callback) {
              callback(res.data);
            }
          }
        })
        .catch((err) => {
          if (errCallback) {
            errCallback();
          }
        });
    },

    //字典数据格式化
    taxTypeFormate(data) {
      return utils.selectDictLabel(this.taxTypeDict, data);
    },

    registrationFormate(data) {
      return utils.selectDictLabel(this.registrationDict, data);
    },

    lzjdFormate(data) {
      return utils.selectDictLabel(this.lzjdDict, data);
    },

    dateFormatter(data) {
      return utils.dateFormatter(data);
    },
    industryFormate(data) {
      return utils.selectDictLabel(this.industryDict, data);
    },

    projectCategoryFormate(data) {
      return utils.selectDictLabel(this.projectCategoryDict, data);
    },

    projectStatusFormate(data) {
      return utils.selectDictLabel(
        this.projectStatusDict,
        "project_status-" + data
      );
    },
  },
};
</script>

<style lang="scss" scoped>
</style>
